# Maintainer: Krassy Boykinov <kboykinov@teamcentrixx.com>
pkgname=libunibreak
pkgver=6.1
pkgrel=0
pkgdesc="Implementation of the line breaking and word breaking algorithms"
url="https://github.com/adah1972/libunibreak"
arch="all"
license="Zlib"
subpackages="$pkgname-dev"
source="https://github.com/adah1972/libunibreak/releases/download/libunibreak_${pkgver//./_}/libunibreak-$pkgver.tar.gz"
options="!check" # no tests

prepare() {
 	default_prepare
	update_config_sub
}

build() {
	CFLAGS="$CFLAGS -O2 -flto=auto" \
	./configure \
		--prefix=/usr \
		--host=$CHOST \
		--build=$CBUILD \
		--disable-static
	make
}

package() {
	make DESTDIR="$pkgdir" install
}

sha512sums="
8ffde29a9b90ddcbfabb61d7302ffe3b17473cd6d30fe1a4403d857e6191291d7e7a6f23bde58654155ed95f4a0f31e082cdf424a82da46722a811291ef38c2f  libunibreak-6.1.tar.gz
"
